$(function(){
	$('.tujia').Validform({
		tiptype:function(msg,o,cssctl){
			if(!o.obj.is("form")){//验证表单元素时o.obj为该表单元素，全部验证通过提交表单时o.obj为该表单对象;
				var objtip=o.obj.next('div.info').find(".Validform_checktip");
				cssctl(objtip,o.type);
				objtip.text(msg);
				var infoObj=o.obj.next('div.info');
				if(o.type==2){
					infoObj.fadeOut(200);
				}else{
					if(infoObj.is(":visible")){return;}
					var left=o.obj.offset().left,
						top=o.obj.offset().top;
					infoObj.css({
						left:left+260,
						top:top-10
					}).show().animate({
						top:top+1	
					},200);
				}
			}
		},
		datatype:{
			'en':/^[A-Za-z]+$/i,
			'u':/^[chr(0xa1)-chr(0xff)0-9a-zA-Z_]{4-12}$/,
			'password':/^([a-zA-Z0-9]|[._]){6,19}$/
		}
	});
});
